﻿using CrazyMVSamLibrary.Base;
using CrazyMVSamLibrary.Model;

namespace CrazyMVSamLibrary.Function
{
    internal class PointPromotion : Promotion
    {
        public OperatorType m_Optype;
        public int X { get; set; }
        public int Y { get; set; }

        public PointPromotion(OperatorType optype)
        {
            this.mType = PromotionType.Point;
            this.m_Optype = optype;
        }
        
        public override float[] GetInput()
        {
            return new float[2] { X, Y };
        }
        
        public override float[] GetLable()
        {
            if (this.m_Optype == OperatorType.ADD)
            {
                return new float[1] { 1 };
            }
            else
            {
                return new float[1] { 0 };
            }
        }
    }
}